var app = getApp()

Page({
    data:{
        myData:"this is a new page",
        myArr:[{
            id:0,
            name:"katennn"
        },{
            id:1,
            name:"jack"
        },{
            id:2,
            name:"rose"
        }]
    },
    showData:function(){
        var globalData = app.globalData;
        this.setData({
            myArr:[...this.data.myArr,{id:this.data.myArr.length,name:'bkb'}]        
        })
        console.log('page data',this.data.myArr);
    },
    showToast:function(){
        wx.showToast({
            title: '成功',
            icon: 'success',
            duration: 2000
            })

    },
    showScrollTop:function(){

        

    }

})